<template>
	<view class="content">
		<image class="logo" src="/static/logo.png"></image>
		<view>
			<div>
				<button type="primary" @click="shutDownMachine">关机</button>
				<button type="primary" @click="rebootMachine">重启</button>
				<button type="primary" @click="timingTurnOnMachine(120)">定时120秒后开机</button>
			</div>
		</view>
	</view>
</template>

<script>
// 获取 module
var rebootModule = uni.requireNativePlugin("reboot-module")


export default {
	data() {
		return {
			title: 'Reboot-Module',
			result: 0,
			result1:0,
		};
	},
	onLoad() {},
	methods: {
		shutDownMachine(){
			rebootModule.shutDownMachine();
		},
		rebootMachine(){
			rebootModule.rebootMachine();
		},
		timingTurnOnMachine(times){
			rebootModule.timingTurnOnMachine(times);
		},
	}
};
</script>

<style>
.content {
	text-align: center;
	height: 400upx;
}

.logo {
	height: 200upx;
	width: 200upx;
	margin-top: 200upx;
}

.title {
	font-size: 36upx;
	color: #8f8f94;
}

button {
	margin-top: 30upx;
	margin-bottom: 30upx;
}

.button-sp-area {
	margin: 0 auto;
	width: 60%;
}

.content {
	text-align: center;
	height: 400upx;
}

.wrapper {
	flex-direction: column;
	justify-content: center;
}

.button {
	width: 200px;
	margin-top: 30px;
	margin-left: 20px;
	padding-top: 20px;
	padding-bottom: 20px;
	border-width: 2px;
	border-style: solid;
	border-color: #458b00;
	background-color: #458b00;
}

.text {
	font-size: 30px;
	color: #666666;
	text-align: center;
}
</style>
